#pragma once
#include "ui_thread.h"
#include <QMainWindow>
#include <QTcpServer>
#include <QTcpSocket>
#include <thrad_1.h>

#define PORT 8000

class thread : public QMainWindow {
    Q_OBJECT
    
public:
    thread(QWidget* parent = nullptr);
    ~thread();

private slots:
    void new_connection();
    // void client_info_slot();


private:
    Ui_thread* ui;
    QTcpServer *serversocket;  // TCP服务器套接字，用于监听和接受客户端连接

};